let Toast = {}

Toast.show = function (options) {
    let data = {
        title: '加载中...',
        icon: 'loading',
        duration: 1000 * 60
    }
    if (typeof options == 'string') {
        data.title = options
    }
    else {
        data = Object.assign(data, options) 
    }
    wx.showToast(data);
}

Toast.hide = function (options) {
    wx.hideToast();
}

export default Toast;